package org.lyd.spring.ioc;

import org.lyd.spring.ioc.bean.Byd;
import org.lyd.spring.ioc.bean.Dog;
import org.lyd.spring.ioc.bean.User;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;

@SpringBootApplication
public class SpringIoc01Application {

    public static void main(String[] args) {
        ConfigurableApplicationContext ioc = SpringApplication.run(SpringIoc01Application.class, args);
        System.out.println("=========容器创建完成============");
//        User bean = ioc.getBean(User.class);
//        System.out.println("运行：" + bean);
        Byd byd = ioc.getBean(Byd.class);
        System.out.println("运行：" + byd);
    }

}
